In the broader markets, the mid and smallcap indices were up 0.3% each, underperforming the BSE benchmark index which gained 0.5%.
The Sensex and the Nifty had touched a low of 27,921 and 8,349 respectively.
The 30-share Sensex ended down 35 points at 26,349 and the 50-share Nifty ended down 20 points at 7,864.
Markets shrugged off RBI's neutral stance on key policy rates.
The top gainers on the Sensex were Cipla, Bharti Airtel, Maruti Suzuki, Hero Moto & Sesa Sterlite.
HDFC and Infosys contribute the most to today's rally.
Sensex hit a record high of 27,225.85 and Nifty hit a record high of 8,141.90 in the intra-day trades today.
For the seven months since February 2014, the benchmark index surged nearly 27%.
The 30-share Sensex ended 117 points higher at 26,560 and the 50-share Nifty gained 31 points to end at 7,936.
Metal stocks lose ground with Hindalco, Tata Steel, Sesa Sterlite down 4-10%.
Markets extended gains for the fourth consecutive day tracking gains in banks, capital goods and oil and gas majors.
Sensex ended up 190 points at 25,519 and Nifty climbed 57 points to end at 7,626.
Tata Steel, SBI, Infosys and L&T were among the top gainers for the day.
Sensex gained nearly 0.4% or 96 points at 26087 level while Nifty ended up by 42 points or 0.5% at 7,791.40 level.
Infosys, Wipro and HUL among the top losers for the day.
Markets will remain closed today on account of voting for the general elections in Mumbai constituencies.